import { useEffect, useRef, useState } from "react";


function MyComponents() {
 const [isruing,setIsruing]=useState(false)
const [time,setTime]=useState(0)
const timeRef=useRef(null)
const startTimeRef=useRef(0)

function start(){

}
function stop(){

}
function zero(){

}
function getTime(){
  return "00:00:00"
}
useEffect(()=>{

},[isruing])
  return (
    <div className="counter">
        <h1>{getTime()}</h1>
        <div className="btnBox">
          <button className="start" onClick={start}>开始</button>
          <button className="zero" onClick={zero}>归零</button>
          <button className="stop" onClick={stop}>停止</button>
        </div>
    </div>
  );
}
export default MyComponents;
